package com.skp.shaphan.menus;

import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import javax.swing.JMenuItem;

import com.skp.shaphan.ShaphanApp;
import com.skp.shaphan.actions.ExecuteSQLAction;
import com.skp.shaphan.actions.FormatSQLAction;
import com.skp.shaphan.ui.windows.ImportSQLWindow;

/**
 * Formats the SQL Statement that is currently active
 * @author Stephen Phillips
 *
 */
public class ImportSQLMenuItem extends JMenuItem implements ActionListener {
	/**
	 * Create the new menu item
	 */
	public ImportSQLMenuItem() {
		super("Import");
		this.setMnemonic('I');
		this.addActionListener(this);
	}

	/**
	 * Execute when the menu is clicked
	 */
	@Override
	public void actionPerformed(ActionEvent e) {
		ImportSQLWindow win = new ImportSQLWindow(ShaphanApp.getMainWindow());
		win.setVisible(true);
	}
}
